package com.xmx.springboot_quick2.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @Author Xumx
 * @Date 2021/4/1 18:31
 * @Version 1.0
 */
@Controller
public class Quick2 {

    @Value("${name}")
    private String name;

    @Value("${person.addr}")
    private String addr;

    @RequestMapping("/quick2")
    @ResponseBody
    public String quick2(){
        //获得配置文件的信息

        return "name:"+name+",addr:"+addr;
    }

}
